package mediatorPattern;

public class Landlord extends Colleague {

    private String houseInfo;


    public Landlord(Mediator mediator) {
        super(mediator);
    }

    public String getHouseInfo() {
        return houseInfo;
    }

    public void postHouseInfo(String houseInfo) {
        this.houseInfo = houseInfo;
        System.out.println("发布房源信息："+houseInfo);
        mediator.notify(this,"postHouseInfo");
    }

    public void receiveViewRequest(Tenant tenant) {
        System.out.println("接收到租客的查看请求"+tenant.name+"房源信息："+houseInfo);
    }

}
